import request from '@/utils/request'

// 查询菜品分类列表
export function listDishesType(query) {
  return request({
    url: '/dishes/dishesType/list',
    method: 'get',
    params: query
  })
}

// 查询菜品分类详细
export function getDishesType(typeId) {
  return request({
    url: '/dishes/dishesType/' + typeId,
    method: 'get'
  })
}

// 新增菜品分类
export function addDishesType(data) {
  return request({
    url: '/dishes/dishesType',
    method: 'post',
    data: data
  })
}

// 修改菜品分类
export function updateDishesType(data) {
  return request({
    url: '/dishes/dishesType',
    method: 'put',
    data: data
  })
}

// 删除菜品分类
export function delDishesType(typeId) {
  return request({
    url: '/dishes/dishesType/' + typeId,
    method: 'delete'
  })
}
